Skip to content

Geometry

Script Output

SetPoint1D

lua
SetPoint1D(name, x, z)

Set a 1D point to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 1D point
zNumber (double)Z-axis coordinate of 1D point

SetPoint2D

lua
SetPoint2D(name, x, y)

Set a 2D point to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 2D point
yNumber (double)Y-axis coordinate of 2D point

SetPoint3D

lua
SetPoint3D(name, x, y, z)

Set a 3D point to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 3D point
yNumber (double)Y-axis coordinate of 3D point
zNumber (double)Z-axis coordinate of 3D point

SetLine1D

lua
SetLine1D(name, x, z, vx, vz)

Set a 1D line to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 1D line
zNumber (double)Z-axis coordinate of 1D line
vxNumber (double)X-axis direction of 1D line's direction vector
vzNumber (double)Z-axis direction of 1D line's direction vector

SetLine2D

lua
SetLine2D(name, x, y, vx, vy)

Set a 2D line to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 2D line
yNumber (double)Y-axis coordinate of 2D line
vxNumber (double)X-axis direction of 2D line's direction vector
vyNumber (double)Y-axis direction of 2D line's direction vector

SetLine3D

lua
SetLine3D(name, x, y, z, vx, vy, vz)

Set a 3D line to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 3D line
yNumber (double)Y-axis coordinate of 3D line
zNumber (double)Z-axis coordinate of 3D line
vxNumber (double)X-axis direction of 3D line's direction vector
vyNumber (double)Y-axis direction of 3D line's direction vector
vzNumber (double)Z-axis direction of 3D line's direction vector

SetSegment1D

lua
SetSegment1D(name, sx, sz, ex, ez)

Set a 1D segment to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
sxNumber (double)X-axis coordinate of 1D segment start point
szNumber (double)Z-axis coordinate of 1D segment start point
exNumber (double)X-axis coordinate of 1D segment end point
ezNumber (double)Z-axis coordinate of 1D segment end point

SetSegment2D

lua
SetSegment2D(name, sx, sy, ex, ey)

Set a 2D segment to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
sxNumber (double)X-axis coordinate of 2D segment start point
syNumber (double)Y-axis coordinate of 2D segment start point
exNumber (double)X-axis coordinate of 2D segment end point
eyNumber (double)Y-axis coordinate of 2D segment end point

SetSegment3D

lua
SetSegment3D(name, sx, sy, sz, ex, ey, ez)

Set a 3D segment to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
sxNumber (double)X-axis coordinate of 3D segment start point
syNumber (double)Y-axis coordinate of 3D segment start point
szNumber (double)Z-axis coordinate of 3D segment start point
exNumber (double)X-axis coordinate of 3D segment end point
eyNumber (double)Y-axis coordinate of 3D segment end point
ezNumber (double)Z-axis coordinate of 3D segment end point

SetPlane

lua
SetPlane(name, x, y, z, vx, vy, vz)

Set a plane to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of plane
yNumber (double)Y-axis coordinate of plane
zNumber (double)Z-axis coordinate of plane
vxNumber (double)X-axis direction of plane's normal vector
vyNumber (double)Y-axis direction of plane's normal vector
vzNumber (double)Z-axis direction of plane's normal vector

SetCircle1D

lua
SetCircle1D(name, x, z, r)

Set a 1D circle to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 1D circle center
zNumber (double)Z-axis coordinate of 1D circle center
rNumber (double)Radius of 1D circle

SetCircle2D

lua
SetCircle2D(name, x, y, r)

Set a 2D circle to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 2D circle center
yNumber (double)Y-axis coordinate of 2D circle center
rNumber (double)Radius of 2D circle

SetCircle3D

lua
SetCircle3D(name, x, y, z, r, rx, ry, rz)

Set a 3D circle to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 3D circle center
yNumber (double)Y-axis coordinate of 3D circle center
zNumber (double)Z-axis coordinate of 3D circle center
rNumber (double)Radius of 3D circle
rxNumber (double)Rotation angle around X-axis
ryNumber (double)Rotation angle around Y-axis
rzNumber (double)Rotation angle around Z-axis

SetRing1D

lua
SetRing1D(name, x, z, r1, r2)

Set a 1D ring to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 1D ring center
zNumber (double)Z-axis coordinate of 1D ring center
r1Number (double)Inner radius of 1D ring
r2Number (double)Outer radius of 1D ring

SetRing2D

lua
SetRing2D(name, x, y, r1, r2)

Set a 2D ring to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 2D ring center
yNumber (double)Y-axis coordinate of 2D ring center
r1Number (double)Inner radius of 2D ring
r2Number (double)Outer radius of 2D ring

SetRing3D

lua
SetRing3D(name, x, y, z, r1, r2, rx, ry, rz)

Set a 3D ring to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 3D ring center
yNumber (double)Y-axis coordinate of 3D ring center
zNumber (double)Z-axis coordinate of 3D ring center
r1Number (double)Inner radius of 3D ring
r2Number (double)Outer radius of 3D ring
rxNumber (double)Rotation angle around X-axis
ryNumber (double)Rotation angle around Y-axis
rzNumber (double)Rotation angle around Z-axis

SetCylinder

lua
SetCylinder(name, cx1, cy1, cz1, cx2, cy2, cz2, r)

Set a cylinder to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
cx1Number (double)X-axis coordinate of base 1 center
cy1Number (double)Y-axis coordinate of base 1 center
cz1Number (double)Z-axis coordinate of base 1 center
cx2Number (double)X-axis coordinate of base 2 center
cy2Number (double)Y-axis coordinate of base 2 center
cz2Number (double)Z-axis coordinate of base 2 center
rNumber (double)Radius of cylinder base

SetWindow1D

lua
SetWindow1D(name, sx, sz, ex, ez)

Set a 1D window to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
sxNumber (double)X-axis coordinate of 1D window start point
szNumber (double)Z-axis coordinate of 1D window start point
exNumber (double)X-axis coordinate of 1D window end point
ezNumber (double)Z-axis coordinate of 1D window end point

SetWindow2D

lua
SetWindow2D(name, sx, sy, ex, ey)

Set a 2D window to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
sxNumber (double)X-axis coordinate of 2D window start point
syNumber (double)Y-axis coordinate of 2D window start point
exNumber (double)X-axis coordinate of 2D window end point
eyNumber (double)Y-axis coordinate of 2D window end point

SetCircleWindow1D

lua
SetCircleWindow1D(name, x, z, r)

Set a 1D circular window to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 1D circular window center
zNumber (double)Z-axis coordinate of 1D circular window center
rNumber (double)Radius of 1D circular window

SetCircleWindow2D

lua
SetCircleWindow2D(name, x, y, r)

Set a 2D circular window to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)X-axis coordinate of 2D circular window center
yNumber (double)Y-axis coordinate of 2D circular window center
rNumber (double)Radius of 2D circular window

SetBox

lua
SetBox(name, sx, sy, sz, ex, ey, ez)

Set a box to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
sxNumber (double)X-axis coordinate of box start point
syNumber (double)Y-axis coordinate of box start point
szNumber (double)Z-axis coordinate of box start point
exNumber (double)X-axis coordinate of box end point
eyNumber (double)Y-axis coordinate of box end point
ezNumber (double)Z-axis coordinate of box end point

SetOrientedBox

lua
SetOrientedBox(name, cx, cy, cz, sx, sy, sz, rx, ry, rz)

Set an oriented box to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
cxNumber (double)X-axis coordinate of oriented box center point
cyNumber (double)Y-axis coordinate of oriented box center point
czNumber (double)Z-axis coordinate of oriented box center point
sxNumber (double)Size of oriented box in X-axis direction
syNumber (double)Size of oriented box in Y-axis direction
szNumber (double)Size of oriented box in Z-axis direction
rxNumber (double)Rotation angle around X-axis
ryNumber (double)Rotation angle around Y-axis
rzNumber (double)Rotation angle around Z-axis

SetPose

lua
SetPose(name, x, y, z, W, X, Y, Z)

Set a pose to script output.

Parameters:

ParameterTypeDescription
nameStringOutput variable name
xNumber (double)Position X-axis coordinate
yNumber (double)Position Y-axis coordinate
zNumber (double)Position Z-axis coordinate
WNumber (double)Quaternion W component
XNumber (double)Quaternion X component
YNumber (double)Quaternion Y component
ZNumber (double)Quaternion Z component

IM Display

DrawPolygon1D

lua
DrawPolygon1D(im, color, polygon)

Draw a 1D polygon to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringText color
polygonArrayVertex coordinate array of 1D polygon

DrawPolygon2D

lua
DrawPolygon2D(im, color, polygon)

Draw a 2D polygon to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringText color
polygonArrayVertex coordinate array of 2D polygon

DrawPolygon3D

lua
DrawPolygon3D(im, color, polygon)

Draw a 3D polygon to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringText color
polygonArrayVertex coordinate array of 3D polygon

DrawPoint1D

lua
DrawPoint1D(im, color, x, z)

Draw a 1D point to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringPoint color
xNumber (double)X-axis coordinate of 1D point
zNumber (double)Z-axis coordinate of 1D point

DrawPoint2D

lua
DrawPoint2D(im, color, x, y)

Draw a 2D point to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 2D point
yNumber (double)Y-axis coordinate of 2D point

DrawPoint3D

lua
DrawPoint3D(im, color, x, y, z)

Draw a 3D point to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 3D point
yNumber (double)Y-axis coordinate of 3D point
zNumber (double)Z-axis coordinate of 3D point

DrawLine1D

lua
DrawLine1D(im, color, x, z, vx, vz)

Draw a 1D line to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 1D line
zNumber (double)Z-axis coordinate of 1D line
vxNumber (double)X-axis direction of 1D line's direction vector
vzNumber (double)Z-axis direction of 1D line's direction vector

DrawLine2D

lua
DrawLine2D(im, color, x, y, vx, vy)

Draw a 2D line to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 2D line
yNumber (double)Y-axis coordinate of 2D line
vxNumber (double)X-axis direction of 2D line's direction vector
vyNumber (double)Y-axis direction of 2D line's direction vector

DrawLine3D

lua
DrawLine3D(im, color, x, y, z, vx, vy, vz)

Draw a 3D line to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 3D line
yNumber (double)Y-axis coordinate of 3D line
zNumber (double)Z-axis coordinate of 3D line
vxNumber (double)X-axis direction of 3D line's direction vector
vyNumber (double)Y-axis direction of 3D line's direction vector
vzNumber (double)Z-axis direction of 3D line's direction vector

DrawSegment1D

lua
DrawSegment1D(im, color, sx, sz, ex, ez)

Draw a 1D segment to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
sxNumber (double)X-axis coordinate of 1D segment start point
szNumber (double)Z-axis coordinate of 1D segment start point
exNumber (double)X-axis coordinate of 1D segment end point
ezNumber (double)Z-axis coordinate of 1D segment end point

DrawSegment2D

lua
DrawSegment2D(im, color, sx, sy, ex, ey)

Draw a 2D segment to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
sxNumber (double)X-axis coordinate of 2D segment start point
syNumber (double)Y-axis coordinate of 2D segment start point
exNumber (double)X-axis coordinate of 2D segment end point
eyNumber (double)Y-axis coordinate of 2D segment end point

DrawSegment3D

lua
DrawSegment3D(im, color, sx, sy, sz, ex, ey, ez)

Draw a 3D segment to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
sxNumber (double)X-axis coordinate of 3D segment start point
syNumber (double)Y-axis coordinate of 3D segment start point
szNumber (double)Z-axis coordinate of 3D segment start point
exNumber (double)X-axis coordinate of 3D segment end point
eyNumber (double)Y-axis coordinate of 3D segment end point
ezNumber (double)Z-axis coordinate of 3D segment end point

DrawPlane

lua
DrawPlane(im, color, x, y, z, vx, vy, vz)

Draw a plane to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of plane
yNumber (double)Y-axis coordinate of plane
zNumber (double)Z-axis coordinate of plane
vxNumber (double)X-axis direction of plane's normal vector
vyNumber (double)Y-axis direction of plane's normal vector
vzNumber (double)Z-axis direction of plane's normal vector

DrawCircle1D

lua
DrawCircle1D(im, color, x, z, r)

Draw a 1D circle to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 1D circle center
zNumber (double)Z-axis coordinate of 1D circle center
rNumber (double)Radius of 1D circle

DrawCircle2D

lua
DrawCircle2D(im, color, x, y, r)

Draw a 2D circle to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 2D circle center
yNumber (double)Y-axis coordinate of 2D circle center
rNumber (double)Radius of 2D circle

DrawCircle3D

lua
DrawCircle3D(im, color, x, y, z, r, rx, ry, rz)

Draw a 3D circle to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 3D circle center
yNumber (double)Y-axis coordinate of 3D circle center
zNumber (double)Z-axis coordinate of 3D circle center
rNumber (double)Radius of 3D circle
rxNumber (double)Rotation angle around X-axis
ryNumber (double)Rotation angle around Y-axis
rzNumber (double)Rotation angle around Z-axis

DrawRing1D

lua
DrawRing1D(im, color, x, z, r1, r2)

Draw a 1D ring to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 1D ring center
zNumber (double)Z-axis coordinate of 1D ring center
r1Number (double)Inner radius of 1D ring
r2Number (double)Outer radius of 1D ring

DrawRing2D

lua
DrawRing2D(im, color, x, y, r1, r2)

Draw a 2D ring to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 2D ring center
yNumber (double)Y-axis coordinate of 2D ring center
r1Number (double)Inner radius of 2D ring
r2Number (double)Outer radius of 2D ring

DrawRing3D

lua
DrawRing3D(im, color, x, y, z, r1, r2, rx, ry, rz)

Draw a 3D ring to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 3D ring center
yNumber (double)Y-axis coordinate of 3D ring center
zNumber (double)Z-axis coordinate of 3D ring center
r1Number (double)Inner radius of 3D ring
r2Number (double)Outer radius of 3D ring
rxNumber (double)Rotation angle around X-axis
ryNumber (double)Rotation angle around Y-axis
rzNumber (double)Rotation angle around Z-axis

DrawCylinder

lua
DrawCylinder(im, color, cx1, cy1, cz1, cx2, cy2, cz2, r)

Draw a cylinder to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
cx1Number (double)X-axis coordinate of base 1 center
cy1Number (double)Y-axis coordinate of base 1 center
cz1Number (double)Z-axis coordinate of base 1 center
cx2Number (double)X-axis coordinate of base 2 center
cy2Number (double)Y-axis coordinate of base 2 center
cz2Number (double)Z-axis coordinate of base 2 center
rNumber (double)Radius of cylinder base

DrawWindow1D

lua
DrawWindow1D(im, color, sx, sz, ex, ez)

Draw a 1D window to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
sxNumber (double)X-axis coordinate of 1D window start point
szNumber (double)Z-axis coordinate of 1D window start point
exNumber (double)X-axis coordinate of 1D window end point
ezNumber (double)Z-axis coordinate of 1D window end point

DrawWindow2D

lua
DrawWindow2D(im, color, sx, sy, ex, ey)

Draw a 2D window to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
sxNumber (double)X-axis coordinate of 2D window start point
syNumber (double)Y-axis coordinate of 2D window start point
exNumber (double)X-axis coordinate of 2D window end point
eyNumber (double)Y-axis coordinate of 2D window end point

DrawCircleWindow1D

lua
DrawCircleWindow1D(im, color, x, z, r)

Draw a 1D circular window to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
xNumber (double)X-axis coordinate of 1D circular window center
zNumber (double)Z-axis coordinate of 1D circular window center
rNumber (double)Radius of 1D circular window

DrawCircleWindow2D

lua
DrawCircleWindow2D(im, color, x, y, r)

Draw a 2D circular window to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringCircular window color
xNumber (double)X-axis coordinate of circular window center
yNumber (double)Y-axis coordinate of circular window center
rNumber (double)Radius of circular window

DrawBox

lua
DrawBox(im, color, sx, sy, sz, ex, ey, ez)

Draw a box to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
sxNumber (double)X-axis coordinate of box start point
syNumber (double)Y-axis coordinate of box start point
szNumber (double)Z-axis coordinate of box start point
exNumber (double)X-axis coordinate of box end point
eyNumber (double)Y-axis coordinate of box end point
ezNumber (double)Z-axis coordinate of box end point

DrawOrientedBox

lua
DrawOrientedBox(im, color, cx, cy, cz, sx, sy, sz, rx, ry, rz)

Draw an oriented box to specified IM display.

Parameters:

ParameterTypeDescription
imIntegerImage register index
colorStringColor
cxNumber (double)X-axis coordinate of oriented box center point
cyNumber (double)Y-axis coordinate of oriented box center point
czNumber (double)Z-axis coordinate of oriented box center point
sxNumber (double)Size of oriented box in X-axis
syNumber (double)Size of oriented box in Y-axis
szNumber (double)Size of oriented box in Z-axis
rxNumber (double)Rotation angle around X-axis
ryNumber (double)Rotation angle around Y-axis
rzNumber (double)Rotation angle around Z-axis

AI-Vision, Making 3D Measurement Easier